package com.pss.oauth2.controller;

//import io.jsonwebtoken.Jwts;
import org.apache.tomcat.util.net.openssl.ciphers.Authentication;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;
import java.nio.charset.StandardCharsets;

@RestController
@RequestMapping("/user")
public class UserController {
    /**
     */
//    @RequestMapping("getCurrentUser1")
//    public Object getCurrentUser1(Authentication authentication, HttpServletRequest request) {
//        String head = request.getHeader("Authorization");
//        String token = head.replace("bearer" ,"");
//
//        return Jwts.parser().setSigningKey("test_key".getBytes(StandardCharsets.UTF_8))
//                .parseClaimsJws(token)
//                .getBody();
//    }
}
